package model;

import java.io.*;

public class FacilitiesDTO implements Cloneable, Serializable {

	private static final long serialVersionUID = 1L;
	
	private int facilityID;
    private String facilityName;
    private String type;
    private String description;
    private int capacity;

    public FacilitiesDTO () {
    }

    public FacilitiesDTO (int facilityIDIn) {
          this.facilityID = facilityIDIn;
    }

    public int getFacilityID() {
          return this.facilityID;
    }
    public void setFacilityID(int facilityIDIn) {
          this.facilityID = facilityIDIn;
    }

    public String getFacilityName() {
          return this.facilityName;
    }
    public void setFacilityName(String facilityNameIn) {
          this.facilityName = facilityNameIn;
    }

    public String getType() {
          return this.type;
    }
    public void setType(String typeIn) {
          this.type = typeIn;
    }

    public String getDescription() {
          return this.description;
    }
    public void setDescription(String descriptionIn) {
          this.description = descriptionIn;
    }

    public int getCapacity() {
          return this.capacity;
    }
    public void setCapacity(int capacityIn) {
          this.capacity = capacityIn;
    }

    public void setAll(int facilityIDIn,
          String facilityNameIn,
          String typeIn,
          String descriptionIn,
          int capacityIn) {
          this.facilityID = facilityIDIn;
          this.facilityName = facilityNameIn;
          this.type = typeIn;
          this.description = descriptionIn;
          this.capacity = capacityIn;
    }

    public boolean hasEqualMapping(FacilitiesDTO valueObject) {

          if (valueObject.getFacilityID() != this.facilityID) {
                    return(false);
          }
          if (this.facilityName == null) {
                    if (valueObject.getFacilityName() != null)
                           return(false);
          } else if (!this.facilityName.equals(valueObject.getFacilityName())) {
                    return(false);
          }
          if (this.type == null) {
                    if (valueObject.getType() != null)
                           return(false);
          } else if (!this.type.equals(valueObject.getType())) {
                    return(false);
          }
          if (this.description == null) {
                    if (valueObject.getDescription() != null)
                           return(false);
          } else if (!this.description.equals(valueObject.getDescription())) {
                    return(false);
          }
          if (valueObject.getCapacity() != this.capacity) {
                    return(false);
          }

          return true;
    }

	@Override
	public String toString() {
		return "FacilitiesDTO [facilityID=" + facilityID + ", facilityName="
				+ facilityName + ", type=" + type + ", description="
				+ description + ", capacity=" + capacity + "]";
	}

	
		
	
}

